import {request} from '@/service/request';
import {Config} from "@/views/system/config/index";

// 查询config列表
export function fetchConfigPage(page: Common.Page<Config>, searchData: any) {
    return request<Common.Page<Config>>({url:'/sys/config/list',  data:{page, searchData },method:'post'});
}




// 新增config
export function fetchAddConfig(data: Config) {
    return request({url:'/sys/config/', data,method:'post'});
}

// 修改config
export function fetchUpdateConfig(data: Config) {
    return request({url:'/sys/config', data,method:'put'});
}

// 查询config详细
export function fetchConfig(id: Common.IdType) {
    return request<Config>({url:`/sys/config/${id}`, method:'get'});
}

// 删除config
export function fetchDelConfig(ids: Common.IdType[]) {
    return request({url:`/sys/config/${ids}`, method:'delete'});
}


